// path模块
// path模块用于处理文件路径

// 加载模块 
const path = require('path');

// path.join(path1,path2...)返回一个拼接后的规范路径
// console.log( path.join('a','b/c','d') );// 'a\b\c\d'
// console.log( path.join('a','b/c','/d') );// 'a\b\c\d'
// console.log( path.join('a','b/c','./d') );// 'a\b\c\d'
// console.log( path.join('a','b/c','../d') );// 'a\b\d'

// path.resolve(path1,path2...)返回一个拼接后的规范的绝对路径
// console.log( path.resolve('a','b/c','d') );// 'D:\works\BJ-0619\day12\a\b\c\d'
// console.log( path.resolve('a','b/c','/d') );// 'D:\d'
// console.log( path.resolve('a','b/c','./d') );// 'D:\works\BJ-0619\day12\a\b\c\d'
// console.log( path.resolve('a','b/c','../d') );// 'D:\works\BJ-0619\day12\a\b\d'
